home *** CD-ROM | disk | FTP | other *** search
/ Aminet 1 / Aminet - June 1993 [Walnut Creek].iso / ab20 / datacomm / vltphone.lzh / bix.vlt < prev    next >
Encoding:
Text File  |  1990-08-08  |  1.4 KB  |  49 lines

  1. /* Bix logger */
  2.  
  3. address vlt
  4. call openport(bixport)
  5. "trap add autodeactivate install 'fier' [rx (address BIXPORT TI)]"
  6. "trap add 11 instal 'in:' [rx (address BIXPORT BI)]"
  7. "trap add 12 install 'name:' [rx (address BIXPORT BI)]"
  8. "trap add 13 autodeactivate install 'NO CARRIER' [rx (address BIXPORT DX)]"
  9. "trap add 14 autodeactivate install 'me?' [rx (address BIXPORT LI)]"
  10. "trap add 15 autodeactivate install 'ord:' [rx (address BIXPORT PW)]"
  11. "trap add 16 autodeactivate install 'tymnet: call cleared by request' [rx (address BIXPORT CC)]"
  12.  
  13. call delay 150
  14. send "
  15. "
  16. do dummy1 = 1
  17.     do dummy2 = 1
  18.         token = getpkt(bixport)
  19.         if token = '0000 0000'x then leave
  20.         msg = getarg(token)
  21.         call reply(token)
  22.         select
  23.             when msg = ti then send 'a'
  24.             when msg = bi then send 'xxbixyyy
  25. '
  26.             when msg = li then send 'elian
  27. '
  28.             when msg = CC then do
  29.                 message '{BIX Cleared the call!}'
  30.                 leave dummy1
  31.                 end
  32.             when msg = pw then do
  33.                 send 'xxxxxxxxxx
  34. '
  35.                 leave dummy1
  36.                 end
  37.             when msg = dx then message '{Tymnet hung up!}'
  38.             end
  39.         end
  40.     call waitpkt(bixport)
  41. end
  42. call closeport(bixport)
  43. "trap remove {11}"
  44. "trap remove {12}"
  45. "trap remove {13}"
  46. "trap remove {14}"
  47. "trap remove {15}"
  48. "trap remove {16}"
  49.  
  50. exit 0
  51.  
  52.  
  53.